﻿<%@ Page Title="" Language="C#" MasterPageFile="~/TracNghiem.Master" AutoEventWireup="true"
    CodeBehind="SearchPage.aspx.cs" Inherits="TracNghiemChonTruong.SearchPage" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
    <script type="text/javascript">

        $(document).ready(function () {
            $("#<%=txtDiemChuan.ClientID %>").keypress(function (e) {
                // Check if the value of the input is valid
                var key = e.keyCode || e.charCode;
                if ((key >= 48 && key <= 57) || key == 8 || key == 46 || (key >= 37 && key <= 40)) {
                    var maxvalue = 30;
                    var minvalue = 1;
                    var value = $(this).val() * 10 + (key - 48);
                    if ((value <= maxvalue && value >= minvalue) || key == 8 || key == 46 || (key >= 37 && key <= 40)) {
                    } else e.preventDefault(e);
                }
                else e.preventDefault(e);
            });

        });
    </script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentHeader" runat="server">
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="ContentBody" runat="server">
    <div id="step3">
        <p class="group">
            Bạn hãy chọn hai nhóm sở thích phù hợp nhất của bạn:</p>
        <div class="line">
            <div class="float-left">
                Nhóm sở thích 1:
            </div>
            <div class="float-left">
                <asp:DropDownList runat="server" ID="ddlSoThich1" />
            </div>
            <div class="float-left">
                Điểm chuẩn dự kiến của bạn:
            </div>
            <div class="float-left">
                <asp:TextBox runat="server" ID="txtDiemChuan" />
                +/-
            </div>
        </div>
        <div class="clear">
        </div>
        <div class="line">
            <div class="float-left">
                Nhóm sở thích 2:
            </div>
            <div class="float-left">
                <asp:DropDownList runat="server" ID="ddlSoThich2" />
            </div>
        </div>
        <div class="clear">
        </div>
        <div class="line">
            <div class="float-left">
                <asp:Button ID="hylBack" runat="server" Text="Trở về" OnClick="RaiseBackEvent" />
            </div>
            <div class="float-right">
                <asp:Button ID="hylSearch" runat="server" Text="Tìm kiếm" OnClick="RaiseSearchEvent" />
                <asp:Button ID="hylExcel" runat="server" Text="Xuất Excel" OnClick="RaiseExcelEvent" />
            </div>
        </div>
        <div class="clear">
        </div>
        <div>
            <asp:DataGrid runat="server" ID="dtgDiemChuan" AutoGenerateColumns="False" Width="100%">
                <Columns>
                    <asp:BoundColumn HeaderText="Mã Trường" DataField="MaTruong" />
                    <asp:BoundColumn HeaderText="Tên Trường" DataField="TenTruong" />
                    <asp:BoundColumn HeaderText="Tên Ngành" DataField="TenNganh" />
                    <asp:BoundColumn HeaderText="Khối" DataField="KhoiThi" />
                    <asp:BoundColumn HeaderText="Hệ" DataField="MaHe" />
                    <asp:BoundColumn HeaderText="Điểm chuẩn 2012" DataField="Diem" />
                </Columns>
                <HeaderStyle BackColor="Brown" ForeColor="White"></HeaderStyle>
            </asp:DataGrid>
        </div>
        <%--<p class="back-top">
            <a href="#top"><span></span></a>
        </p>
        <p class="go-bottom">
            <a href="#bottom"><span></span></a>
        </p>--%>
    </div>
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="ContentFooter" runat="server">
</asp:Content>
